package com.openatc.optimize.fixedtimeplan.enums;

import lombok.Getter;

/**
 * @author mz
 * @version 1.0
 * @date 2022/7/13 16:00
 */
@Getter
public enum OptTypeEnum {

    FLOW_SPLIT_OPT("flow-split-opt"),CYCLE_OPT("cycle-opt");
    private String value;

    private OptTypeEnum(String value){
        this.value = value;
    }

    public static OptTypeEnum getOptTypeEnumByValue(String type){
        if(type == null){
            return null;
        }
        for(OptTypeEnum optTypeEnum:values()){
            if(type.equals(optTypeEnum.value)){
                return optTypeEnum;
            }
        }
        return null;
    }

}
